Ext.onReady(function(){

	//================================================================
	// Set ExtJS proterty.
	//================================================================
	Ext.BLANK_IMAGE_URL = m_ContextName + '/common/ext-2.2/resources/images/default/s.gif';
	Ext.state.Manager.setProvider(new Ext.state.CookieProvider());
	Ext.QuickTips.init();
	
	//================================================================
	// Set Layout using Ext Viewport
	//================================================================
	var viewport = new Ext.Viewport({
		layout: 'border',
		items: [
			new Ext.tree.TreePanel({
				region: 'center',
				id: 'id_panel_tree',
				contentEl: 'id_div_panel_tree',
				//collapsible: true,
				//split: true,
				width: 200,
				minSize: 150,
				maxSize: 400,
				margins: '0 0 0 0',
				rootVisible: true,
				//useArrows: true,
				//animate: true,
				lines: false,
				autoScroll: true,
				enableDD: false,
				dataUrl: m_RootUrl,
				root: new Ext.tree.AsyncTreeNode({
					text: m_RootText
					//expanded: true
				})
			})
		]
	});

	
	
	//================================================================
	// Action Function
	//================================================================
	if (m_isOpen == true)
	{
		Ext.getCmp('id_panel_tree').getRootNode().expand();
	}
	
	Ext.getCmp('id_panel_tree').on('click', function(n){
		if (n.leaf)
		{
			if (m_RootType == '2')
			{
				if (n.id == '11')
				{
					top.frameContents.location.href = m_ContextName + '/analysis/analysis600Main.do?id=' + n.id;
				}
				else
				{
					Ext.Msg.alert('확인', '선택하신 페이지는 분석하실수 없습니다.');
				}
			}
		}
	});
	
	
});

	

	
	
	
	
	
	
	
	
	